package com.gpay.erp.services.purchase.impl;

import com.gpay.erp.core.dao.BaseDao;
import com.gpay.erp.core.dao.page.PagerModel;
import com.gpay.erp.services.purchase.PaidApplicationSubService;
import com.gpay.erp.services.purchase.bean.PaidApplicationSub;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.List;

/**
 * Created by wuzonghui on 15/11/6.
 */
@Service
public class PaidApplicationSubServiceImpl implements PaidApplicationSubService {
    @Resource
    private BaseDao dao;
    @Override
    public int insert(PaidApplicationSub paidApplicationSub) {
        return dao.insert("paidApplicationSub.insert",paidApplicationSub);
    }

    @Override
    public int delete(PaidApplicationSub paidApplicationSub) {
        return dao.delete("paidApplicationSub.deleteById",paidApplicationSub);
    }

    @Override
    public int deletes(String[] ids) {
        return 0;
    }

    @Override
    public int update(PaidApplicationSub paidApplicationSub) {
        return dao.update("paidApplicationSub.update",paidApplicationSub);
    }

    @Override
    public PaidApplicationSub selectOne(PaidApplicationSub paidApplicationSub) {
        return null;
    }

    @Override
    public PaidApplicationSub selectById(String id) {
        return (PaidApplicationSub) dao.selectOne("paidApplicationSub.selectById",id);
    }

    @Override
    public PagerModel selectPageList(PaidApplicationSub paidApplicationSub) {
        return null;
    }

    @Override
    public List<PaidApplicationSub> selectList(PaidApplicationSub paidApplicationSub) {
        return dao.selectList("paidApplicationSub.selectByFid",paidApplicationSub);
    }

    @Override
    public HashMap selectTotalByOne(PaidApplicationSub paidApplicationSub){
        return (HashMap) dao.selectOne("paidApplicationSub.selectTotalByOne",paidApplicationSub);
    }
}
